<%@page import="com.wanmait.hotelManage.vo.Admin"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
    <%
    Admin admin=(Admin)request.getAttribute("admin");
    %>
<jsp:include page="/manage/inc/header.jsp"/>
 <jsp:include page="/manage/inc/menu.jsp"/> 
    <!--/sidebar-->
    <div class="main-wrap">

        <div class="crumb-wrap">
            <div class="crumb-list"><i class="icon-font"></i><a href="/jscss/admin/design/">首页</a><span class="crumb-step">&gt;</span><a class="crumb-name" href="/jscss/admin/design/">作品管理</a><span class="crumb-step">&gt;</span><span>新增作品</span></div>
        </div>
        <div class="result-wrap">
            <div class="result-content">
                <form action="/jscss/admin/design/add" method="post" id="myform" name="myform" enctype="multipart/form-data">
                    <table class="insert-tab" width="100%">
                        <tbody>
                        <%
                        if(admin!=null){
                        	
                        	%>
                            <tr>
                                <th><i class="require-red">*</i>原密码：</th>
                                <td>
                                    <input class="common-text required" id="title" name="title" size="50" value="<%=admin.getPassword() %>" type="text">
                                </td>
                            </tr>
                            <%
                        }else{
                    		session.setAttribute("goUrl", request.getHeader("Referer"));
                        	response.sendRedirect(request.getContextPath()+"/manage/login.jsp");
                        	return;
                        }
                        %>
                            <tr>
                                <th>新密码：</th>
                                <td><input class="common-text" name="password" id="password" size="50" value="" type="text"><span id="passwordif"></span></td>
                            </tr>
                            <tr>
                                <th></th>
                                <td>
                                    <input class="btn btn-primary btn6 mr10" id="buttonid" value="提交" type="button">
                                    <input class="btn btn6" value="返回" type="button">
                                </td>
                            </tr>
                        </tbody></table>
                </form>
            </div>
        </div>

    </div>
    <!--/main-->
</div>
 <jsp:include page="/manage/inc/footer.jsp"/> 
 <script>
 $(function(){
	 $("#buttonid").click(function(){
		 var password=$("#password").val();
		 if(password.length==0){
			 $("#passwordif").html("密码不能为空");
		 }
	 })
 })
 </script>